package com.wondream.java.io.example.file;

import java.io.FileOutputStream;
import java.io.IOException;
import java.io.OutputStreamWriter;

public class OutputStreamWriterTest {
    final static String fileName = "./tmp/info.log";

    public static void main(String[] args) throws IOException {
        OutputStreamWriter writer = new OutputStreamWriter(new FileOutputStream(fileName));
        writer.write("hello, world!");
        writer.write(65);
        writer.flush();
        writer.close();
        System.out.println("[[OutputStreamWriterTest.main]] write success. ");
    }
}
